The present invention relates to a data storage device and a method having a control function to perform data transmitting/receiving processing between a host computer and a storage device.
As to a storage device, there is, for example, a disk array device using a plurality of hard disk drives (HDDs). Such a data storage device has one or more storage devices, and a control device performing data transmitting/receiving processing between the host computer and the storage devices. Especially, a control device for a disk array device, which controls a plurality of HDDs with a function of redundant array of independent disks (RAID), has a cache memory capable of being accessed faster in compared to the storage device, and has a read cache function to improve access performance from the host computer as well.
In the data storage device with the read cache function, a pre-fetch function of data from the storage device has been widely used as a method for improving the access performance when sequential read requests are issued from the host computer.
The pre-fetch function of data is a function to preliminarily read data in sequential areas (succeeding areas) to be requested in the next step from the storage device into the cache memory, when it is judged that the read requests issued from the host computer has a sequential access property. The sequential access property means the read requests are continuously issued for the succeeding data areas. The control device judges whether or not the read requests issued from the host computer are ones with the sequential access property, and pre-fetch the data in the sequential areas (succeeding areas) of the storage device to the cache memory before it receives the following requests from the host computer.
The pre-fetch processing of the data provides two main advantages. One advantage is reducing a response time for the following command because the data storage device has started the reading from the storage devices before receiving the following command from the host computer. Another advantage is improving total throughput of the data storage device owing to the reduction in access time to the storage devices as well as the reduction in the response time by pre-fetching data in a certain collected size integrally. The pre-fetch processing of the data is thus a function extremely effective for improving the access performance.
FIG. 10 is an explanatory view of a conventional data pre-fetch function. It is presumed that the first command “0” is a request for reading data of a given size (for example, 256 KB) in first continuous address area. It is supposed that the second command “1” is a request for reading data of a given size (for example, 256 KB) in second continuous address area following the first continuous addresses. Further, the third command “2” is a request for reading data of a given size (for example, 256 KB) in third continuous address area following the second continuous address area. As described, in the case of receiving three consecutive data requests of the given size in the continuous addresses, the control device judges that the read requests are ones having sequential access property, and it pre-fetches the data stored in a following data area. That is, as to the determination whether or not the read requests from the host computer are the requests with the sequential access property, when the data storage device continuously receives the read requests from the host computer to the consecutive data areas more than a prescribed number of times (pre-fetch determination times), the control device determines that the read requests are ones respectively having sequential access property.
Now, a disk control device having a function with which redundant information having a predetermined length of block as a unit is added to data to be recorded into a disc drive is known. In the disk control device, a plurality of sequential data are efficiently pre-fetched and are returned to a host computer with high response by effectively using technology for adding redundant information to each sector of the disk for recording data. For instance, refer to Japanese Published Patent Application 2004-355040.
However, the conventional data pre-fetch function needs to receive the read requests from the host computer more than a prescribed number of times (pre-fetch determination times) until it is determined that the read requests from the host computer are ones having sequential access property. Therefore, the read process for the storage devices has to be repeated at every read requests.
Since it is usual to receive two or three times of requests for determining the pre-fetch, it is hard to enjoy substantial effects of the pre-fetch processing when the sequential read requests from the host computer is completed in two or three times. In other words, the disk control device determines that the read requests are ones having the sequential access property when it receives the read request two or three times, thereby performing the pre-fetch processing for the following data. However, when the read requests are completed in two or three times, the pre-fetched data is not used and results in vain, which probably deteriorates the throughput of the data storage device.
In general, a file system or an interface driver (for instance, a driver for SCSI or Fiber Channel) in the host computer does not always issue a read request having a size equal to the data size of the read request from an application software to a control device in order to respond to the read request. The read request to be issued to the control device has an upper limit for the data size depending on specifications of the file system or the driver. The host computer thus divides the read request from the application etc. into a plurality of read requests with the size within the upper limit to issue the read request to the control device.
Therefore, for example, two or three times of consecutive read requests are issued for reading out the files in such a system mostly dealing with files having a size of around 256 KB, and issuing access commands (specifically, SCSI command of “read”, etc.) having such a divided size as 128 KB due to the specifications of a file system or the interface driver. In this case, the pre-fetch function does not work at all or is not effective even if it works because the pre-fetched data results in no use, if the pre-fetch determination time Is set to be three or more. In actual systems, such a small number of consecutive read requests having the sequential access property are issued frequently.
Thus, it is one of the objects of the present invention to provide a data storage device and a method thereof capable of properly determining read requests having sequential access properties, and improving a response time and throughput of the data storage device as well as reducing the number of access times from a control device the storage devices.